/*
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
package LiveReservations.model;

/**
 *
 * @author Grigorios
 */
public class Rating {

    private int rate;

    public Rating() {
        rate = 0;
    }

    public Rating(int rate) {
        this.rate = rate;
    }

    public int getRate() {
        return rate;
    }

    public void rateUp() {
        rate = Math.min(rate + 1, Integer.MAX_VALUE-1);
    }

    public void rateDown() {
        rate = Math.max(rate - 1, Integer.MIN_VALUE+1);
    }
}
